The Movie Toolbox matrix functions provide two mechanisms for specifying points and rectangles. Some of the functions work with standard QuickDraw points and rectangles, which use integer values to identify coordinates. Others, such as the TransformFixedRect function (described on TransformFixedRect ), work with points and rectangles whose coordinates are expressed as fixed-point numbers. By using fixed-point numbers in these points and rectangles, the Movie Toolbox can support a greater degree of precision when defining graphic objects.
The FixedPoint data type defines a fixed point. The FixedRect data type defines a fixed rectangle. Note that both of these structures define the x coordinate before the y coordinate. This is different from the standard QuickDraw structures.
struct FixedPoint
{
Fixed x; /* point's x coordinate as fixed-point number */
Fixed y; /* point's y coordinate as fixed-point number */
};
typedef struct FixedPoint FixedPoint;
struct FixedRect
{
Fixed left; /* x coordinate of upper-left corner */
Fixed top; /* y coordinate of upper-left corner */
Fixed right; /* x coordinate of lower-right corner */
Fixed bottom; /* y coordinate of lower-right corner */
};
typedef struct FixedRect FixedRect;